import { ref, computed } from "vue";
import { defineStore } from "pinia";

export const useStore = defineStore(
  "store",
  () => {
    // 存的数据值
    const count = ref(1);
    const count2= ref(2);
    return { count ,count2 };
  },
  {
    persist: {
      key: "store",
      // 修改为 sessionStorage，默认为 localStorage
      storage: window.sessionStorage,
     
    },
  }
);
